<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>鼠标移入加文字动画加载</title>
  </head>
  <style>
    body {
      margin: 0;
    }
    .box {
      width: 1200px;
      height: 370px;
      margin: 50px auto 0;
    }
    .item {
      position: relative;
      width: 280px;
      height: 370px;
      background-color: aqua;
      float: left;
      margin: 0 10px;
    }
    .item img {
      width: 280px;
      height: 370px;
    }
    .item-mask {
      position: absolute;
      top: 0;
      left: 0;
      width: 280px;
      height: 370px;
      background-color: rgba(0, 0, 0, 0);
      transition: background-color ease 1.5s;
    }
    .item-title {
      position: absolute;
      top: -50px;
      left: 20px;
      color: #fff;
      font-size: 20px;
      transition: top ease 1.5s;
    }
    .item:hover .item-mask {
      background-color: rgba(0, 0, 0, 0.5);
    }
    .item:hover .item-title {
      top: 250px;
    }
  </style>
  <body>
    <div class="box">
      <div class="item">
        <img
          src="https://gw.alicdn.com/bao/upload/i3/6000000007863/O1CN01oCQ34I27xIu1eCgpI_!!6000000007863-0-yinhe.jpg"
          alt=""
        />
        <div class="item-mask"></div>
        <div class="item-title">《听闻远方的你》</div>
      </div>
      <div class="item">
        <img
          src="https://gw.alicdn.com/bao/upload/i4/6000000003372/O1CN01ifKoVh1amQAg7jwA6_!!6000000003372-0-yinhe.jpg"
          alt=""
        />
      </div>
      <div class="item">
        <img
          src="https://gw.alicdn.com/bao/upload/O1CN01avpStI1M4XlgKpSrW_!!6000000001381-0-yinhe.jpg"
          alt=""
        />
      </div>
      <div class="item">
        <img
          src="https://gw.alicdn.com/bao/upload/O1CN01I8nK8F1FJTN42Ta9C_!!6000000000466-0-yinhe.jpg"
          alt=""
        />
      </div>
    </div>
  </body>
</html>
